<?php

class StudentTransfer_Form_Transfer extends Sfs_Form
{


   public $arrayData;
    function __construct($options=null){
        $locale = Bootstrap::$config['resources']['locale']['default'];
        $path = APPLICATION_PATH."/modules/student/languages/$locale/data.ini";
        $ini = new Zend_Config_Ini($path);
        $this->arrayData = $ini->get('array_data')->toArray();
        parent::__construct($options);
    }
    /**
     * initialization routine
     *
     * @return void
     */
    public function init()
    {
        $this->setMethod('post');
        $this->addElement('hidden', 'sn', array(
            'label'      => 'sn',
            'filters'    => array('StringTrim'),
            'validators' => array('int'),
            'decorators' => $this->noElementDecorator,
            )
        );
        $this->addElement('text', 'year', array(
            'label'      => 'year',
            'required'   => true,
            'size' => 3,
            'filters'    => array('StringTrim'),
            'validators' => array('int')
            )
        );
        $this->addElement('text', 'semester', array(
            'label'      => 'semester',
            'required'   => true,
            'size' => 3,
            'filters'    => array('StringTrim'),
            'validators' => array('int')
            )
        );
        $this->addElement('select', 'causation_kind', array(
            'label'      => 'causation_kind',
            'required'   => true,
        //  'size' => 3,
            'filters'    => array('StringTrim'),
            'validators' => array('int')
            )
        );
        $this->addElement('hidden', 'student_sn', array(
            'label'      => 'student_sn',
            //'required'   => true,
            'filters'    => array('StringTrim'),
            'validators' => array('int'),
            'decorators' => $this->noElementDecorator,
            )
        );
        $this->addElement('text', 'county', array(
            'label'      => 'county',
            'required'   => true,
            'size' => 10,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'school_name', array(
            'label'      => 'school_name',
            'required'   => true,
            'size' => 10,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'school_id', array(
            'label'      => 'school_id',
            //'required'   => true,
            'size' => 10,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'date', array(
            'label'      => 'date',
            'required'   => true,
            'size' => 10,
            'filters'    => array('StringTrim'),
            'validators' => array('date')
            )
        );
        $this->addElement('text', 'approve_organ', array(
            'label'      => 'approve_organ',
            'size' => 10,
            //'required'   => true,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'causation', array(
            'label'      => 'causation',
            'size' => 10,
            //'required'   => true,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'approve_date', array(
            'label'      => 'approve_date',
            'size' => 10,
            //'required'   => true,
            'filters'    => array('StringTrim'),
            'validators' => array('date')
            )
        );
        $this->addElement('text', 'approve_word', array(
            'label'      => 'approve_word',
            'size' => 10,
            //'required'   => true,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'approve_number', array(
            'label'      => 'approve_number',
            'size' => 10,
            //'required'   => true,
            'filters'    => array('StringTrim','StripTags'),
        //  'validators' => array()
            )
        );
        $this->addElement('text', 'teacher_sn', array(
            'label'      => 'teacher_sn',
            //'required'   => true,
            'filters'    => array('StringTrim'),
            'validators' => array('int')
            )
        );

    }


}

